package com.kuangstudy.controller;

import com.kuangstudy.entity.Weibo;
import com.kuangstudy.service.weibo.WeiBoRandomListService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author renyitong
 * @version 1.0.0
 * @createTime 2023年09月19日
 * @Description
 */
@RestController
@Api(tags = "微博榜单换一换")
public class WeiBoRandomListController {

    @Autowired
    private WeiBoRandomListService weiBoRandomListService;


    @PostMapping("/weibo/rand/data")
    @ApiOperation("模拟微博推荐的10条帖子")
    public List<Weibo> randomWeiboList(){
        List<Weibo> weiboList = weiBoRandomListService.randomDataWeibo();
        return weiboList;
    }

}
